<template>
    <div class="list">
        <img :src="item.img" alt="">
        <van-badge :content="num">
            <p>{{item.title}}</p>
        </van-badge>
    </div>
</template>
<script>
export default {
    props:['item'],
    setup(props) {
        console.log(props.item.content.length); 
        let num = props.item.content.length
        return {num}
    }
}
</script>
<style lang="scss" scoped>
.list{
    display: flex;
    margin: 10px;
    padding: 10px;
    border-bottom: 1px solid #ccc;
    img{
        width:60px;
        height:60px;
        border-radius: 6px;

    }
}
</style>
